package com.zerox.service.impl;

import com.zerox.mapper.SysUserMapper;
import com.zerox.pojo.SysUser;
import com.zerox.service.SysUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SysUserServiceImpl implements SysUserService {

    @Autowired
    private SysUserMapper sysUserMapper;

    @Override
    public SysUser login(String login_name, String password) {
        return sysUserMapper.login(login_name, password);
    }

    @Override
    public List<SysUser> list(int page, Integer limit) {
        return sysUserMapper.list(page, limit);
    }

    @Override
    public SysUser selectByUser_id(Integer user_id) {
        return sysUserMapper.selectByUser_id(user_id);
    }

    @Override
    public int update(SysUser sysUser) {
        return sysUserMapper.update(sysUser);
    }

    @Override
    public int delete(Integer user_id) {
        return sysUserMapper.delete(user_id);
    }
}
